#include "Component.h"
#include <iostream>

using namespace std;

Component::Component(string name){
	this->_name = name;
}

Component::~Component(){
}

void Component::Add(const Component* c){
	cout<< "Cannot add to a leaf" <<endl;
}

void Component::Remove(const Component* c){
	cout<< "Cannot romove from a leaf" <<endl;
}

void Component::Display(int depth){
	for (int i = 0; i < depth; i++)
	{
		cout<< "-";
	}
	cout<< _name <<endl;
}
